package com.lanhu.designpattern.proxy.dynamic;

/**
 * @author 蓝狐
 */
public class DynamicDatasource {

    public final static ThreadLocal<String> local = new ThreadLocal<>();

    private DynamicDatasource () {
    }

    public static String get(){
        return local.get();
    }

    public static void set(String source){
        local.set(source);
    }

    public static void set(int year){
        set("db_" + year);

    }

}
